package student.stu23002146.chapter10;

import java.io.FileOutputStream;
import java.io.OutputStream;

public class demo10{
    public static void main(String[] args) throws Exception {
        // 创建一个文件字节输出流，并指定输出文件名称
        OutputStream out = new FileOutputStream("C:\\Users\\PC\\IdeaProjects\\java202312\\src\\student\\stu23002146\\chapter10//jiangruihua.txt");
        String str = "aaaa";
        byte[] b = str.getBytes();
        for (int i = 0; i < b.length; i++) {
            out.write(b[i]);
        }
        out.close();
    }
}